package com.bdqn.mapper.MaterialType;

import com.bdqn.entity.MaterialType;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface MaterialTypeMapper {
    /**
     * 些MaterialType的增删改查
     */

    /**
     * 按照条件查询MaterialType并且实行分页
     */
    List<MaterialType> selectMaterialType(@Param("MaterialNumber") String MaterialNumber,@Param("NameOfGoods") String NameOfGoods, @Param("page") Integer page,@Param("limit")  Integer limit);

    /**
     * 根据id查询MaterialType
     * @param id
     * @return
     */
    MaterialType selectMaterialTypeById(int id);
    /**
     * 按照id删除MaterialType
     */
    int deleteMaterialType(int id);
    /**
     * 获取MaterialType总条数或者时待条件 分页时会用上
     */
    int getMaterialTypeCount(@Param("MaterialNumber") String MaterialNumber,@Param("NameOfGoods") String NameOfGoods);
   /**
 修改
    */
    int updateMaterialType(MaterialType materialType);
    /**
     * 添加
     */
    int insertMaterialType(MaterialType materialType);
}
